class Success:
    def __init__(self, data: object, **kwargs):
        self.data = data
        self.code = 200
        self.message = 'success'
        if kwargs.get('pagination'):
            self.page = kwargs.get('pagination').page
            self.page_size = kwargs.get('pagination').page_size
        if kwargs.get('total'):
            self.total = kwargs.get('total')


class Error:
    def __init__(self, message: str, **kwargs):
        self.message = message
        self.code = kwargs.get('code', 500)
